package cn.shujuhai.common.config;

import org.springframework.cache.CacheManager;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cache.concurrent.ConcurrentMapCacheManager;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Author: NiuYaHu
 * @Date: 2024/12/9 10:39
 * @Description:
 **/

@Configuration
@EnableCaching
public class CacheConfig {
    @Bean
    public CacheManager cacheManager() {
        return new ConcurrentMapCacheManager("loginFailureCache", "lockCache", "sys_setting", "idempotentCache");
    }
}